import java.util.Date;
import static java.lang.Math.*;
//import java.sql.*;


/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 0
 * Date: 2023-03-18
 * Time: 14:51
 */
class Student {
    private String name;
    private int age;
    public   static String classRoom = "301";

    public Student() {
        /*this.name  = "luyunlong";
        this.age = 18;*/
        this("luyunlong",18);
        System.out.println("不调用参数的构造方法！");
    }

    /*public Student(String name) {
        this.name = name;
    }

    public Student(String name, int age) {
        this.name = name;
        this.age = age;
    }*/
    public Student(String name, int age) {
        this.name = name;
        this.age = age;
        System.out.println("调用两个参数的构造方法!");
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public void doClass() {
        System.out.println(this.name+"上课");
    }
    public void print() {
        System.out.println("姓名："+this.name+" 年龄: "+ this.age);
    }

    /*public Student(String name, int age, String classRoom) {
        this.name = name;
        this.age = age;
        this.classRoom = classRoom;
    }*/
    public static void funcStatic() {
        System.out.println("funcStatic().........");
    }


}

public class Test {

    public static void func1() {

    }
    public static void main(String[] args) {
        func1();
        Student.funcStatic();

        /*Student student1 = new Student("zhangsan",18);
        Student student2 = student1;*/

      /*  Student student1 = new Student("zhangsan",18);
        student1 = new Student("zhangsan2",18);
        student1 = new Student("zhangsan3",18);*/

       /* Student student1 = null;
        System.out.println(student1.classRoom);//*/
    }

    public static void main6(String[] args) {
        Student student1 = new Student("zhangsan",18);
        Student student2 = new Student("lisi",6);
        Student student3 = new Student("wangwu",28);
        /*System.out.println("教室是："+student1.classRoom);
        System.out.println("教室是："+student2.classRoom);
        System.out.println("教室是："+student3.classRoom);*/

        System.out.println("教室是："+Student.classRoom);
    }


    public static void main5(String[] args) {
        Student student = new Student();
        //student.name = "zhangsan";
        student.setName("zhangsan");
        //student.age = 10;
        student.setAge(10);
        System.out.println(student.getName());

        student.print();
    }

    public static void main4(String[] args) {
        double x = 19.9;
        double y = 20.8;
        //double result = Math.sqrt(Math.pow(x, 2) + Math.pow(y, 2));
        double result = sqrt(pow(x, 2) + pow(y, 2));
    }

    public static void main3(String[] args) {
        java.util.Date date = new java.util.Date();
        /*int[] array = {1,2,3,4};
        Arrays.sort(array);*/
    }

    public static void main2(String[] args) {
        Student student = new Student();
        //student.name = "zhangsan";
        //student.age = 10;
        student.print();



    }

    public static void main1(String[] args) {
        Student student = new Student();
        student.print();
    }


}
